package com.example.demo.entity;

import com.fasterxml.jackson.annotation.JsonFormat;

public class ProductEntity {
    private int id = -1;
    //产品身份码
    private String productCode = null;
    //产品名称
    private String productName = null;
    //批次
    private String batch = null;
    //加工人员
    private String worker = null;
    //加工日期
    @JsonFormat(pattern = "yyyy-MM-dd", timezone = "GMT+8")//转换日期格式
    private String processingDate = null;
    //加工车间
    private String workshop = null;
    //产品尺寸外观
    private String productSize = null;
    //加工方法
    private String processingMethod = null;
    //页面起始位置
    private int start;
    //每一面的数量
    private int limit;

    private int page;

    public ProductEntity() {
    }

    public ProductEntity(int id, String productCode, String productName, String batch, String worker, String processingDate, String workshop, String productSize, String processingMethod, int start, int limit, int page) {
        this.id = id;
        this.productCode = productCode;
        this.productName = productName;
        this.batch = batch;
        this.worker = worker;
        this.processingDate = processingDate;
        this.workshop = workshop;
        this.productSize = productSize;
        this.processingMethod = processingMethod;
        this.start = start;
        this.limit = limit;
        this.page = page;
    }

    public int getId() {
        return id;
    }

    public void setId(int id) {
        this.id = id;
    }

    public String getProductCode() {
        return productCode;
    }

    public void setProductCode(String productCode) {
        this.productCode = productCode;
    }

    public String getProductName() {
        return productName;
    }

    public void setProductName(String productName) {
        this.productName = productName;
    }

    public String getBatch() {
        return batch;
    }

    public void setBatch(String batch) {
        this.batch = batch;
    }

    public String getWorker() {
        return worker;
    }

    public void setWorker(String worker) {
        this.worker = worker;
    }

    public String getProcessingDate() {
        return processingDate;
    }

    public void setProcessingDate(String processingDate) {
        this.processingDate = processingDate;
    }

    public String getWorkshop() {
        return workshop;
    }

    public void setWorkshop(String workshop) {
        this.workshop = workshop;
    }

    public String getProductSize() {
        return productSize;
    }

    public void setProductSize(String productSize) {
        this.productSize = productSize;
    }

    public String getProcessingMethod() {
        return processingMethod;
    }

    public void setProcessingMethod(String processingMethod) {
        this.processingMethod = processingMethod;
    }

    public int getStart() {
        return start;
    }

    public void setStart(int start) {
        this.start = start;
    }

    public int getLimit() {
        return limit;
    }

    public void setLimit(int limit) {
        this.limit = limit;
    }

    public int getPage() {
        return page;
    }

    public void setPage(int page) {
        this.page = page;
    }

    @Override
    public String toString() {
        return "ProductEntity{" +
                "id=" + id +
                ", productCode='" + productCode + '\'' +
                ", productName='" + productName + '\'' +
                ", batch='" + batch + '\'' +
                ", worker='" + worker + '\'' +
                ", processingDate='" + processingDate + '\'' +
                ", workshop='" + workshop + '\'' +
                ", productSize='" + productSize + '\'' +
                ", processingMethod='" + processingMethod + '\'' +
                ", workshop='" + workshop + '\'' +
                '}';
    }
}
